package com.szholly.plug.safe.entity.role;

import com.szholly.utils.util.StringUtils;
import com.szholly.data.general.*;

/**
 * 定义角色委托实体类
 */
public class RoleChangeEntity extends RowBase {

	private static final long serialVersionUID = -4336770122891621550L;

	/**
	 * 委托人ID
	 */
	public final static String FIELD_I_WT_USERID = "S_WT_USERID";

	/**
	 * 被委托者ID
	 */
	public final static String FIELD_I_BWT_USERID = "S_BWT_USERID";

	/**
	 * 角色ID
	 */
	public final static String FIELD_I_ROLEID = "S_ROLEID";
	
	/**
	 * 登记开始时间
	 */
	public final static String FIELD_DJ_BEGINTIME = "D_DJ_BEGINTIME";
	
	/**
	 * 登记结束时间
	 */
	public final static String FIELD_DJ_ENDTIME = "D_DJ_ENDTIME";
	
	/**
	 * 委托开始时间
	 */
	public final static String FIELD_WT_BEGINTIME = "D_WT_BEGINTIME";
	
	/**
	 * 委托结束时间
	 */
	public final static String FIELD_WT_ENDTIME = "D_WT_ENDTIME";
	
	/**
	 * 是否可用
	 */
	public final static String FIELD_ISUSE = "S_ISUSE";

	/**
	 * 获取委托用户ID
	 * 
	 * @return
	 */
	public int getWTUserID() {
		return StringUtils.objectToInt(getValue(GlobalDataType.Int32,
				FIELD_I_WT_USERID));
	}

	/**
	 * 设置委托用户ID
	 * 
	 * @param value
	 */
	public void setWTUserID(String value) {
		setValue(FIELD_I_WT_USERID, value);
	}

	/**
	 * 获取被委托用户ID
	 * 
	 * @return
	 */
	public int getBWTUserID() {
		return StringUtils.objectToInt(getValue(GlobalDataType.Int32,
				FIELD_I_BWT_USERID));
	}

	/**
	 * 设置被委托用户ID
	 * 
	 * @param value
	 */
	public void setBWTUserID(String value) {
		setValue(FIELD_I_BWT_USERID, value);
	}

	/**
	 * 获取角色ID
	 * 
	 * @return
	 */
	public int getRoleID() {
		return StringUtils.objectToInt(getValue(GlobalDataType.Int32,
				FIELD_I_ROLEID));
	}

	/**
	 * 设置角色ID
	 * 
	 * @param value
	 */
	public void setRoleID(String value) {
		setValue(FIELD_I_ROLEID, value);
	}
}